--
-- PostgreSQL database dump
--

-- Dumped from database version 16.3 (Debian 16.3-1.pgdg120+1)
-- Dumped by pg_dump version 16.3 (Debian 16.3-1.pgdg120+1)

SET statement_timeout = 0;
SET lock_timeout = 0;
SET idle_in_transaction_session_timeout = 0;
SET client_encoding = 'UTF8';
SET standard_conforming_strings = on;
SELECT pg_catalog.set_config('search_path', '', false);
SET check_function_bodies = false;
SET xmloption = content;
SET client_min_messages = warning;
SET row_security = off;

SET default_tablespace = '';

SET default_table_access_method = heap;

--
-- Name: forecast; Type: TABLE; Schema: public; Owner: postgres
--

CREATE TABLE public.forecast (
    id integer NOT NULL,
    "dateTime" timestamp without time zone NOT NULL,
    temperature double precision NOT NULL,
    "weatherCondition" character varying NOT NULL,
    "regionId" integer NOT NULL
);


ALTER TABLE public.forecast OWNER TO postgres;

--
-- Name: forecast_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--

CREATE SEQUENCE public.forecast_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.forecast_id_seq OWNER TO postgres;

--
-- Name: forecast_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--

ALTER SEQUENCE public.forecast_id_seq OWNED BY public.forecast.id;


--
-- Name: region; Type: TABLE; Schema: public; Owner: postgres
--

CREATE TABLE public.region (
    id integer NOT NULL,
    "regionType" integer NOT NULL,
    "accountId" integer NOT NULL,
    name character varying NOT NULL,
    "parentRegion" character varying NOT NULL,
    latitude_1 double precision NOT NULL,
    longitude_1 double precision NOT NULL,
    latitude_2 double precision NOT NULL,
    longitude_2 double precision NOT NULL,
    poi boolean NOT NULL
);


ALTER TABLE public.region OWNER TO postgres;

--
-- Name: region_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--

CREATE SEQUENCE public.region_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.region_id_seq OWNER TO postgres;

--
-- Name: region_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--

ALTER SEQUENCE public.region_id_seq OWNED BY public.region.id;


--
-- Name: region_type; Type: TABLE; Schema: public; Owner: postgres
--

CREATE TABLE public.region_type (
    id integer NOT NULL,
    type character varying
);


ALTER TABLE public.region_type OWNER TO postgres;

--
-- Name: region_type_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--

CREATE SEQUENCE public.region_type_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.region_type_id_seq OWNER TO postgres;

--
-- Name: region_type_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--

ALTER SEQUENCE public.region_type_id_seq OWNED BY public.region_type.id;


--
-- Name: user; Type: TABLE; Schema: public; Owner: postgres
--

CREATE TABLE public."user" (
    id integer NOT NULL,
    "firstName" character varying NOT NULL,
    "lastName" character varying NOT NULL,
    email character varying NOT NULL,
    password character varying NOT NULL
);


ALTER TABLE public."user" OWNER TO postgres;

--
-- Name: user_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--

CREATE SEQUENCE public.user_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.user_id_seq OWNER TO postgres;

--
-- Name: user_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--

ALTER SEQUENCE public.user_id_seq OWNED BY public."user".id;


--
-- Name: weather; Type: TABLE; Schema: public; Owner: postgres
--

CREATE TABLE public.weather (
    id integer NOT NULL,
    "regionId" integer NOT NULL,
    temperature double precision NOT NULL,
    humidity double precision NOT NULL,
    "windSpeed" double precision NOT NULL,
    "weatherCondition" character varying NOT NULL,
    "precipitationAmount" double precision NOT NULL,
    "measurementDateTime" timestamp without time zone NOT NULL
);


ALTER TABLE public.weather OWNER TO postgres;

--
-- Name: weather_condition; Type: TABLE; Schema: public; Owner: postgres
--

CREATE TABLE public.weather_condition (
    id integer NOT NULL,
    condition character varying NOT NULL
);


ALTER TABLE public.weather_condition OWNER TO postgres;

--
-- Name: weather_condition_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--

CREATE SEQUENCE public.weather_condition_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.weather_condition_id_seq OWNER TO postgres;

--
-- Name: weather_condition_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--

ALTER SEQUENCE public.weather_condition_id_seq OWNED BY public.weather_condition.id;


--
-- Name: weather_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--

CREATE SEQUENCE public.weather_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.weather_id_seq OWNER TO postgres;

--
-- Name: weather_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--

ALTER SEQUENCE public.weather_id_seq OWNED BY public.weather.id;


--
-- Name: weather_to_forecast; Type: TABLE; Schema: public; Owner: postgres
--

CREATE TABLE public.weather_to_forecast (
    id integer NOT NULL,
    "weatherId" integer NOT NULL,
    "weatherForecast" integer NOT NULL
);


ALTER TABLE public.weather_to_forecast OWNER TO postgres;

--
-- Name: weather_to_forecast_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--

CREATE SEQUENCE public.weather_to_forecast_id_seq
    AS integer
    START WITH 1
    INCREMENT BY 1
    NO MINVALUE
    NO MAXVALUE
    CACHE 1;


ALTER SEQUENCE public.weather_to_forecast_id_seq OWNER TO postgres;

--
-- Name: weather_to_forecast_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--

ALTER SEQUENCE public.weather_to_forecast_id_seq OWNED BY public.weather_to_forecast.id;


--
-- Name: forecast id; Type: DEFAULT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.forecast ALTER COLUMN id SET DEFAULT nextval('public.forecast_id_seq'::regclass);


--
-- Name: region id; Type: DEFAULT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.region ALTER COLUMN id SET DEFAULT nextval('public.region_id_seq'::regclass);


--
-- Name: region_type id; Type: DEFAULT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.region_type ALTER COLUMN id SET DEFAULT nextval('public.region_type_id_seq'::regclass);


--
-- Name: user id; Type: DEFAULT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public."user" ALTER COLUMN id SET DEFAULT nextval('public.user_id_seq'::regclass);


--
-- Name: weather id; Type: DEFAULT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.weather ALTER COLUMN id SET DEFAULT nextval('public.weather_id_seq'::regclass);


--
-- Name: weather_condition id; Type: DEFAULT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.weather_condition ALTER COLUMN id SET DEFAULT nextval('public.weather_condition_id_seq'::regclass);


--
-- Name: weather_to_forecast id; Type: DEFAULT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.weather_to_forecast ALTER COLUMN id SET DEFAULT nextval('public.weather_to_forecast_id_seq'::regclass);


--
-- Data for Name: forecast; Type: TABLE DATA; Schema: public; Owner: postgres
--



--
-- Data for Name: region; Type: TABLE DATA; Schema: public; Owner: postgres
--

INSERT INTO public.region (id, "regionType", "accountId", name, "parentRegion", latitude_1, longitude_1, latitude_2, longitude_2, poi) VALUES (1, 1, 1, 'ewfwefc', 'dsvew', 1, 1, 2, 2, true);


--
-- Data for Name: region_type; Type: TABLE DATA; Schema: public; Owner: postgres
--



--
-- Data for Name: user; Type: TABLE DATA; Schema: public; Owner: postgres
--

INSERT INTO public."user" (id, "firstName", "lastName", email, password) VALUES (1, 'string', 'string', 'string@gmail.com', '$2b$12$Xhw8RtQI2I7Jl8VgkRkXluRwhUssqRQZ0KPN11AceboWkbRkztpzC');


--
-- Data for Name: weather; Type: TABLE DATA; Schema: public; Owner: postgres
--

INSERT INTO public.weather (id, "regionId", temperature, humidity, "windSpeed", "weatherCondition", "precipitationAmount", "measurementDateTime") VALUES (1, 1, 1, 2, 1, 'FOG', 10, '2200-01-10 00:00:00');


--
-- Data for Name: weather_condition; Type: TABLE DATA; Schema: public; Owner: postgres
--

INSERT INTO public.weather_condition (id, condition) VALUES (1, 'CLEAR');
INSERT INTO public.weather_condition (id, condition) VALUES (2, 'CLOUDY');
INSERT INTO public.weather_condition (id, condition) VALUES (3, 'RAIN');
INSERT INTO public.weather_condition (id, condition) VALUES (4, 'SNOW');
INSERT INTO public.weather_condition (id, condition) VALUES (5, 'FOG');
INSERT INTO public.weather_condition (id, condition) VALUES (6, 'STORM');


--
-- Data for Name: weather_to_forecast; Type: TABLE DATA; Schema: public; Owner: postgres
--



--
-- Name: forecast_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres
--

SELECT pg_catalog.setval('public.forecast_id_seq', 1, false);


--
-- Name: region_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres
--

SELECT pg_catalog.setval('public.region_id_seq', 1, true);


--
-- Name: region_type_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres
--

SELECT pg_catalog.setval('public.region_type_id_seq', 1, false);


--
-- Name: user_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres
--

SELECT pg_catalog.setval('public.user_id_seq', 1, true);


--
-- Name: weather_condition_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres
--

SELECT pg_catalog.setval('public.weather_condition_id_seq', 6, true);


--
-- Name: weather_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres
--

SELECT pg_catalog.setval('public.weather_id_seq', 1, true);


--
-- Name: weather_to_forecast_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres
--

SELECT pg_catalog.setval('public.weather_to_forecast_id_seq', 1, false);


--
-- Name: forecast forecast_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.forecast
    ADD CONSTRAINT forecast_pkey PRIMARY KEY (id);


--
-- Name: region region_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.region
    ADD CONSTRAINT region_pkey PRIMARY KEY (id);


--
-- Name: region_type region_type_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.region_type
    ADD CONSTRAINT region_type_pkey PRIMARY KEY (id);


--
-- Name: user user_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public."user"
    ADD CONSTRAINT user_pkey PRIMARY KEY (id);


--
-- Name: weather_condition weather_condition_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.weather_condition
    ADD CONSTRAINT weather_condition_pkey PRIMARY KEY (id);


--
-- Name: weather weather_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.weather
    ADD CONSTRAINT weather_pkey PRIMARY KEY (id);


--
-- Name: weather_to_forecast weather_to_forecast_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
--

ALTER TABLE ONLY public.weather_to_forecast
    ADD CONSTRAINT weather_to_forecast_pkey PRIMARY KEY (id);


--
-- PostgreSQL database dump complete
--